Skip to content

[US-1.2 / OBT-199] Edit a language's name and code in a dialog - #26

Open
levigtri wants to merge 3 commits into
mainfrom
levigft/obt-199-us-12-click-on-a-language-card-and-edit-its-name-or-code-in
Open

[US-1.2 / OBT-199] Edit a language's name and code in a dialog#26
levigtri wants to merge 3 commits into
mainfrom
levigft/obt-199-us-12-click-on-a-language-card-and-edit-its-name-or-code-in

Conversation

@levigtri

@levigtri levigtri commented Jul 5, 2026

Copy link
Copy Markdown
Member

Summary

Lets a language be edited from its card via a pre-filled dialog (name + 3-char ISO 639-3 code). Per the 2026-07 rule change, the direct edit affordance (pencil) is shown only to platform admins — a manager does not edit a language directly; a manager submits an edit request (scoped to languages linked to their own projects) for an admin to approve, delivered by the change-requests feature (separate US). A plain member has no console access at all.

Changes

  1. Editable language cardssrc/components/pages/LanguagesPage.tsx: hover pencil opens the shared dialog pre-filled with the language's name/code; save calls languagesAPI.update, invalidates the store, and re-fetches; duplicate code surfaces the 409 as a toast.
  2. Direct edit is platform-admin-only — same file: the pencil renders only when isPlatformAdmin. (The manager request-edit affordance lives in the change-requests feature.)

Type of Change

  • Feature + business-rule refactor
  • Breaking change

Testing

  • npm run typecheck — clean.
  • npm run lint — 0 errors (only the pre-existing ProjectsPage.tsx warning).
  • npm run build — succeeds.
  • Manual: as a platform admin the pencil appears and edits persist; as a manager/member it is hidden.

Add an edit affordance (pencil on hover) to each language card that opens the
shared dialog pre-filled with the language's name and code. Saving calls the new
languagesAPI.update (PUT), refreshes the store, and surfaces duplicate-code (409)
errors. Add the LanguageUpdate type and updated_at to LanguageResponse (US-1.1).
Show the language edit pencil only when the user is a platform admin.
Direct edit is admin-only per the 2026-07 rule change; managers submit an
edit request (change-requests feature) rather than editing directly.
@levigtri
levigtri force-pushed the levigft/obt-199-us-12-click-on-a-language-card-and-edit-its-name-or-code-in branch from b6cff54 to 6e69ffc Compare July 9, 2026 18:24
Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@coderabbitai

coderabbitai Bot commented Jul 15, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@levigtri, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 42 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: QUIET

Plan: Pro Plus

Run ID: 7777a7cd-bfc0-4022-8e55-fe2117877069

📥 Commits

Reviewing files that changed from the base of the PR and between 130fc4a and d682b2e.

📒 Files selected for processing (4)
  • src/components/pages/LanguagesPage.tsx
  • src/services/api.ts
  • src/types/index.ts
  • src/types/language.ts
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch levigft/obt-199-us-12-click-on-a-language-card-and-edit-its-name-or-code-in

Comment @coderabbitai help to get the list of available commands.

@levigtri levigtri self-assigned this Jul 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant